﻿//  --------------------------------
//  Copyright (c) Bernard White. All rights reserved.
//  This source code is made available under the terms of the Microsoft Public License (Ms-PL)
//  http://mocklet.codeplex.com/license
//  ---------------------------------

using System;

namespace Mocklet.Data
{
    internal static class RandomExtensions
    {
        #region Extension Methods

        public static string NextPhrase(this Random random)
        {
            return Enum.GetName(typeof(Phrases), random.Next(Phrase.MAXVALUE - 1));
        }

        public static Person NextPerson(this Random random)
        {
            return new Person { FirstName = Enum.GetName(typeof(FirstNames), random.Next(FirstName.MAXVALUE - 1)), LastName = Enum.GetName(typeof(LastNames), random.Next(LastName.MAXVALUE - 1)) };
        }

        #endregion Extension Methods
    }
}
